Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: push opened metrics tracked on Android 12 #119

Merged
merged 7 commits into from
Apr 20, 2023

Conversation

mrehan27
Copy link
Contributor

@mrehan27 mrehan27 commented Apr 5, 2023

fixes: https://github.com/customerio/issues/issues/9483
android sdk changes: customerio/customerio-android#184

Changes

  • Requested native SDK to trigger missed lifecycle events so messaging push listener can process notification payload

@mrehan27 mrehan27 requested a review from a team April 5, 2023 16:03
@mrehan27 mrehan27 self-assigned this Apr 5, 2023
@github-actions
Copy link

github-actions bot commented Apr 5, 2023

Pull request title looks good 👍!

If this pull request gets merged, it will cause a new release of the software. Example: If this project's latest release version is 1.0.0. If this pull request gets merged in, the next release of this project will be 1.0.1. This pull request is not a breaking change.

All merged pull requests will eventually get deployed. But some types of pull requests will trigger a deployment (such as features and bug fixes) while some pull requests will wait to get deployed until a later time.

This project uses a special format for pull requests titles. Expand this section to learn more (expand by clicking the ᐅ symbol on the left side of this sentence)...

This project uses a special format for pull requests titles. Don't worry, it's easy!

This pull request title should be in this format:

<type>: short description of change being made

If your pull request introduces breaking changes to the code, use this format:

<type>!: short description of breaking change

where <type> is one of the following:

  • feat: - A feature is being added or modified by this pull request. Use this if you made any changes to any of the features of the project.

  • fix: - A bug is being fixed by this pull request. Use this if you made any fixes to bugs in the project.

  • docs: - This pull request is making documentation changes, only.

  • refactor: - A change was made that doesn't fix a bug or add a feature.

  • test: - Adds missing tests or fixes broken tests.

  • style: - Changes that do not effect the code (whitespace, linting, formatting, semi-colons, etc)

  • perf: - Changes improve performance of the code.

  • build: - Changes to the build system (maven, npm, gulp, etc)

  • ci: - Changes to the CI build system (Travis, GitHub Actions, Circle, etc)

  • chore: - Other changes to project that don't modify source code or test files.

  • revert: - Reverts a previous commit that was made.

Examples:

feat: edit profile photo
refactor!: remove deprecated v1 endpoints
build: update npm dependencies
style: run formatter 

Need more examples? Want to learn more about this format? Check out the official docs.

Note: If your pull request does multiple things such as adding a feature and makes changes to the CI server and fixes some bugs then you might want to consider splitting this pull request up into multiple smaller pull requests.

@mrehan27 mrehan27 changed the title Fix/android 12 opened metrics fix: push opened metrics tracked on Android 12 Apr 5, 2023
@levibostian levibostian removed the request for review from a team April 5, 2023 19:42
@levibostian
Copy link
Contributor

Removed all reviewers since the PR states not to merge it.

Next time, would creating a draft PR work for you? Instead of creating an open PR and ask not to merge it?

I am OK with this, but think that draft PRs would be simpler.

@mrehan27
Copy link
Contributor Author

mrehan27 commented Apr 6, 2023

@levibostian Draft PRs are for incomplete changes. This PR is complete. The not merging caution was there because it is dependent on Android SDK changes and will not compile without native changes being available. The reviewers were added as the ticket is in testing and I wanted it to be reviewed with native PR, we cannot address PR comments after the testing is complete and native SDK is released.

@mrehan27 mrehan27 requested a review from a team April 6, 2023 10:22
Copy link
Contributor

@Shahroz16 Shahroz16 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks okay, no changes are needed apart from changing the snapshot to stable. Once we make the changes, we can approve it.

Comment on lines 20 to 21
// If SDK is already initialized from CIO service using context, initialize the local
// reference with SDK instance
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This comment explains what the code is doing, but it doesn't explain why we are initializing the local SDK reference. What problem this code solves.

A suggestion is that the comment could be modified to answer the question:

Why do we have this code instead of modifying the class from:

private lateinit var customerIO: CustomerIO

to:

private val customerIO = CustomerIO.instance()

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added comments to explain it more.

@mrehan27
Copy link
Contributor Author

@Shahroz16 Updated SDK version to stable release

@mrehan27 mrehan27 merged commit dfd6fbd into main Apr 20, 2023
@mrehan27 mrehan27 deleted the fix/android-12-opened-metrics branch April 20, 2023 20:31
github-actions bot pushed a commit that referenced this pull request Apr 20, 2023
### [2.3.2](2.3.1...2.3.2) (2023-04-20)

### Bug Fixes

* push opened metrics tracked on Android 12 ([#119](#119)) ([dfd6fbd](dfd6fbd))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants